// export {};

let arr: number[] = [1, 2, 3];
arr.forEach((val, i, arr) => {
    console.log(val, i, arr);
});
arr.forEach((val) => {
    console.log(val);
});


function sum(...nums: number[]) {
    let res = 0
    for (const number of nums) {
        res += number
    }
    return res
}

console.log(sum(...arr));
